import java.util.ArrayList;
import java.util.List;

public class GenericTest <T>{
    public static void main(String[] args) {
        List<Fruit> fruits = new ArrayList<>();
        List<Apple> apples = new ArrayList<>();
        fruits.addAll(apples);

        List<? super Apple> list = new ArrayList<>();
        list.add(new BigApple());
        list.add(new Apple());
    }

    public void Show(T t) {
        System.out.println(t.toString());
    }

}

class Fruit {

}

class Apple extends Fruit {

}

class BigApple extends Apple {
}